<!doctype html><html><head><meta charset="utf-8"><meta name="viewport" content="maximum-scale=1,minimum-scale=1,user-scalable=0,width=device-width,initial-scale=1"><meta name="format-detection" content="telephone=no,email=no,date=no,address=no"><link rel="stylesheet" href="../../../global/css/aui.css"><link rel="stylesheet" href="../../../global/css/my-css.css"><style>#aui-header .bg-close{
        width: 3rem!important;
        background-image: url('../../../global/image/topic/posting_tab_delete.png')!important;
        background-position: center!important;
        background-repeat: no-repeat!important;
        background-size: 1.4rem !important;
    }</style></head><body><header class="aui-bar aui-bar-nav" id="aui-header" style="overflow:hidden;"><div class="aui-btn aui-pull-left no-btn bg-close" tapmode onclick="onCancel();"></div><div class="aui-title" tapmode onclick="frmToTop();"></div><a id="btn-pub-post" class="aui-btn aui-pull-right" tapmode onclick="Quick.bindPhoneProxy(onDone)();"><span class="aui-iconfont c-green" style="color: #02BE97;font-size: 16px;">发布</span></a></header></body><script src="../../../config.js"></script><script src="../../../global/script/lib/api.js"></script><script src="../../../global/script/lib/doT.min.js"></script><script src="../../../global/script/mylib.js"></script><script src="../../../app.js"></script><script type="text/javascript">var frmName = 'frm-pub-post';
    apiready = function() {
        window.app.init4Win();
		$api.dom('.aui-title').innerHTML = api.pageParam.title;

        var header = $api.byId('aui-header');
        $api.fixStatusBar(header);
        var headerPos = $api.offset(header);
        var body_h = $api.offset($api.dom('body')).h;
        apix.openFrame({
            name: frmName,
            url: './frm.html',
            rect: {
                x: 0,
                y: headerPos.h,
                w: 'auto',
                h: 'auto'
            },
			allowEdit: true,
			pageParam: api.pageParam
        });

        // android的（硬件）返回按钮
        evt.listenTo('keyback', function(data) {
            onCancel();
        });
    };

	function onCancel() {
		api.execScript({
		    frameName: frmName,
		    script: 'tryCancelPub();'
		});
	}

	function onDone() {
        /*
        if (!app.isLoggedIn()) {
            views.openAuthWin({
                from: "publish-post",
                fid:api.pageParam.fid,
                extratype: api.pageParam.extratype,
                pubFrom: api.pageParam.extratype
            });
            return;
        }
        */

        //if(hasPhone()){
            api.execScript({
    		    frameName: frmName,
    		    script: 'tryPub();'
    		});
        //}
	}

    function enableBtnPub() {
        wlog('enableBtnPub...');
        $apix.enable($api.byId('btn-pub-post'));
    }
    function disableBtnPub() {
        wlog('disableBtnPub...');
        $apix.disable($api.byId('btn-pub-post'));
    }</script></html>